def addArray(strs, dic, array):
    """

    :type dic: object
    """
    #Eric 20241221 增加数据传输头的结构(38字节)
    if strs == "DataTransmissionHeader":
        dic = {"name": "MessageLength", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "协议标识", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "协议版本号", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "数据格式版本号", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "DataTransmissionType", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "预留1", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "传输命令编码", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "发送时间戳", "len": 7, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "发送序列号", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "设备编号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "设备分组编号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "设备组内编号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "预留2 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "分包总数 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "分包序号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "预留3 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "校验码算法 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "预留4 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    #Eric 20241221 增加ACC对账文件信息头的结构(12字节)
    if strs == "ReconciliationDataHeader":
        dic = {"name": "SettleDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "CorpId", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "RecNum", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    #Eric 20241221 对账文件中交易数据包编号的结构(14字节)
    if strs == "TxnPkgId":
        dic = {"name": "数据包类型", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "设备编号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "组包时间戳", "len": 7, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
        array.append(dic)
        dic = {"name": "组包序列号", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
        array.append(dic)
    
    if strs == "SysCardCom_t":
        dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "SysProductCom_t":
        dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "SysAppCom_t":
        dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "SysComHdr_t":
        dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
        array.append(dic)
        dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'],
               "date": "five"}
        array.append(dic)
        dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdJourneyHdr_t":
        dic = {"name": "passengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdPassCommonHdr_t":
        dic = {"name": "passEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'],
               "date": "localtime"}
        array.append(dic)

    if strs == "SysFinDetails_t":
        dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "compensationReason", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdProductValidity_t":
        dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'],
               "date": "localtime"}
        array.append(dic)
        dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
        array.append(dic)
        dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdPassLavHdr_t":
        dic = {"name": "lavSamId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
        array.append(dic)
        dic = {"name": "lavTxnValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavPassExpiryDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'],
               "date": "localtime"}
        array.append(dic)
        dic = {"name": "lavPtsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavMethodOfPayment", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "dataIsValid", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdPurseLavHdr_t":
        dic = {"name": "lavSamId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
        array.append(dic)
        dic = {"name": "lavTxnValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavPtsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavMethodOfPayment", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "dataIsValid", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "SysSecurityHdr_t":
        dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdPurseCommonHdr_t":
        dic = {"name": "purseRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdMultirideCommonHdr_t":
        dic = {"name": "numRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "remainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "SysCardholderCom_t":
        dic = {"name": "cardholderSerialNum", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "cardholderIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "companyId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "classificationLevel", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    if strs == "DevUdMultirideLavHdr_t":
        dic = {"name": "lavSamId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
        array.append(dic)
        dic = {"name": "lavTxnValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavRemainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavPtsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "lavMethodOfPayment", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "dataIsValid", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)
        dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
        array.append(dic)

    return array, dic


# 3.1.2.1	长安通非联机交易
def changAnTongFeiLianJiList():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<h", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "udSubtype", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "本地流水号 LocalTxnSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "PSAM机具号 PosId", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "PSAM物理卡号 SamId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "PSAM流水号 SamSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号 ", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID PosOperId", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "城市代码 CityCode", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "票卡ID CardId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn——实际为“支付方式”", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡计数器 CrdDebitCnt", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理类型 CardModel ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "主卡类型 CrdMKnd", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "子卡类型 CrdSKnd", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易前余额 BefBalance ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 TxnAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "优惠卡类型 UserType", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "应收金额 OrigAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易发生日期 TxnDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 TxnTime", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易认证码 TAC", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡内版本号 CrdVerNo", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易后余额 AftBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易的线路运营商ID ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "上一站点车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票卡有效期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "造成延迟交易的运营模式", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 长安通售充
def changAnTongShouChongList():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "udSubtype", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "本地流水号 LocalTxnSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "ISAM机具号 PosId", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM物理卡号 SamId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM流水号 SamSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID PosOperId", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "城市代码 CityCode", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "票卡ID CardId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn——实际为“支付方式”", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡计数器 CrdDebitCnt", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理类型 CardModel", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "主卡类型 CrdMKnd", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "子卡类型 CrdSKnd", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "业务类型 TransType", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易前余额 BefBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 TxnAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡押金 Deposit", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易后余额 AftBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "售卡日期 SaleDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "售卡方式 SaleMode", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票卡有效期 CardValDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生日期 TxnDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 TxnTime", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡内版本号 CrdVerNo", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "签到批次号 BatchNo", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "密钥授权流水号", "len": 9, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "额度授权流水号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "上笔交易类型", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "上笔交易终端机具号", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "上笔交易金额", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "上笔交易卡计数器", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "上笔交易时间", "len": 7, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "上笔交易前金额", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "上笔交易TAC", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易认证码 TAC", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易的线路运营商ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    return array


# 3.1.3.1	交通卡本地卡非联机交易
def jiaoTongKaBenDiKaFeiLianJi():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "udSubtype", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "本地流水号 LocalTxnSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "ISAM机具号 PosId", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM物理卡号 SamId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM流水号 SamSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID PosOperId", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "票卡ID CardId", "len": 10, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡计数器 CrdDebitCnt", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理类型 CardModel", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    # dic = {"name": "产品类型 ProductTyp", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    dic = {"name": "产品类型 ProductTyp", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "产品子类型 ProductSubTyp", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易前余额 BefBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 TxnAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "优惠卡类型 UserType", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "应收金额 OrigAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易发生日期 TxnDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 TxnTime", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易认证码 TAC", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡内版本号 CrdVerNo", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易后余额 AftBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易的线路运营商ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "上一站点车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票卡有效期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "造成延迟交易的运营模式", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "发卡机构代码", "len": 11, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "商户标识符", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "商户类型", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "城市代码", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "补票类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn——实际为“支付方式”", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    # 预留
    dic = {"name": "预留", "len": 10, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)

    return array


# 3.1.3.2	交通卡异地卡非联机交易
def jiaoTongKaYiDiKaFeiLianJi():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "udSubtype", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "本地流水号 LocalTxnSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "ISAM机具号 PosId", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM物理卡号 SamId", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "ISAM流水号 SamSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID PosOperId", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "票卡ID CardId", "len": 10, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡计数器 CrdDebitCnt", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理类型 CardModel", "len": 1, "str": "B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    # dic = {"name": "产品类型 ProductTyp", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    # array.append(dic)
    dic = {"name": "产品类型 ProductTyp", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "产品子类型 ProductSubTyp", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易前余额 BefBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 TxnAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "优惠卡类型 UserType", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "应收金额 OrigAmt", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易发生日期 TxnDate", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 TxnTime", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易认证码 TAC", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡内版本号 CrdVerNo", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易后余额 AftBalance", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易的线路运营商ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产生交易车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站车站编号", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "上一站点车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票卡有效期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生时间", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "延迟交易的原始发生车站ID", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "造成延迟交易的运营模式", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "发卡机构代码", "len": 11, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "商户标识符", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "商户类型", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "互通城市代码", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "消费密钥版本", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "消费密钥索引", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "算法标识", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "补票类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡物理序列号 CardCsn——实际为“支付方式”", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    # 预留
    dic = {"name": "预留", "len": 10, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)

    return array


# 2.1.3.1	ACC交易-二维码电子车票进站交易
def erWeiMaJinZhanJiaoYi():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备所属车站位置代码", "位置类型", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "模块代码", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "模式", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备编号", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备流水号", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备离线状态", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端订单号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "操作员编码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "二维码扫码时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "记录生成时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "交易类型", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡类型", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "小码用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "补登事件编号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "渠道", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    return array


# 2.1.3.2	ACC交易-二维码电子车票出站交易
def erWeiMaChuZhanJiaoYi():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备所属车站位置代码", "位置类型", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "模块代码", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "模式", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备编号", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备流水号", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备离线状态", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端订单号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "操作员编码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "二维码扫码时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "记录生成时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "交易类型", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡类型", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "小码用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "补登事件编号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "渠道", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    return array


# 2.1.3.3	ACC交易-二维码电子车票补登交易
def erWeiMaBuDengJiaoYi():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备所属车站位置代码", "位置类型", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "模块代码", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "模式", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备编号", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备类型", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备流水号", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "设备离线状态", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "终端订单号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "操作员编码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "二维码扫码时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "记录生成时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "交易类型", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "用户卡类型", "len": 16, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "小码用户ID", "len": 32, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站车站代码", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "被补登进出站时间", "len": 14, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "补登事件编号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    dic = {"name": "渠道", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    return array


# 3.1.1.1	TxnCardIssue
def TxnCardIssue():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "expiryDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return


# 3.1.1.2	TxnProductMultirideIssue
def TxnProductMultirideIssue():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


# 3.1.1.3	TxnProductPassIssue
def TxnProductPassIssue():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "purseRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 3.1.1.4	TxnProductPurseIssue
def TxnProductPurseIssue():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "purseRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 3.1.1.5	TxnProductMultirideExitTicketIssue
def TxnProductMultirideExitTicketIssue():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "numRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "remainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invalidCardSerial Number", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invalidProductIssuer", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invalidLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invalidProductType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 3.1.1.6	TxnProductMultirideAdd
def TxnProductMultirideAdd():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "numRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "remainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavSamId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)

    dic = {"name": "lavTxnValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavRemainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavPtsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavMethodOfPayment", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "dataIsValid", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 3.1.1.9	3.1.1.9	TxnProductMultirideCompensationFare
def TxnProductMultirideCompensationFare():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    # SysComHdr_t
    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # SysCardCom_t
    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # SysAppCom_t
    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # SysProductCom_t
    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # DevUdJourneyHdr_t
    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # DevUdMultirideCommonHdr_t
    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # SysFinDetails_t
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "compensationReason", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    # DevUdProductValidity_t
    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # DevUdMultirideLavHdr_t
    dic = {"name": "lavSamId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "lavTxnValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavRemainingRides", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavPtsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "lavMethodOfPayment", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "dataIsValid", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    # SysSecurityHdr_t
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 3.1.1.10	TxnProductPassCompensationFare
def TxnProductPassCompensationFare():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysFinDetails_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


# 3.1.1.11	TxnProductPurseCompensationFare
def TxnProductPurseCompensationFare():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysFinDetails_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


# 3.1.1.17	TxnProductPurseRefund
def TxnProductPurseRefund():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardholderCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysFinDetails_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "refundReason", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


# 3.1.1.26		TxnCardDepositReceiptReverse
def TxnCardDepositReceiptReverse():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reverseUdsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array

# 3.1.1.27		TxnCardFeeReverse
def TxnCardFeeReverse():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reverseUdsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array

# 3.1.1.20	TxnProductMultirideIssueReverse 取消计次产品发售交易 类似TxnProductMultirideIssue
def TxnProductMultirideIssueReverse():
    array = []
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    #reversedUdsn
    dic = {"name": "reversedUdsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array

# 3.1.1.21	TxnProductPassIssueReverse 取消定期产品发售交易 类似TxnProductPassIssue
def TxnProductPassIssueReverse():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "purseRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    #reversedUdsn
    dic = {"name": "reversedUdsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array

# 3.1.1.22	TxnProductPurseIssueReverse 取消钱包产品发售交易 类似TxnProductPurseIssue
def TxnProductPurseIssueReverse():
    array = []

    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "formatVersion", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnDateTime", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "sourceParticipantId", "len": 4, "str": ">i", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "samId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "serviceParticipantId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionStatus", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cdVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "reconciliationDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "five"}
    array.append(dic)
    dic = {"name": "reservedField", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "udSubtype", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardLifeCycleCount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "cardActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationProviderId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPersonaliseCat", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "appActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "applicationPassengerType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productIssuerId", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productSerialNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productType", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "productActionSequenceNumber", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "Ptsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "invoicePrinted", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "purseRemainingValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "vStartDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vEndDateTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "vDuration", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "Dur"}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": ["位置类型", "00", "线路ID", "车站ID"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    #reversedUdsn
    dic = {"name": "reversedUdsn", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "txnMac", "len": 8, "str": ">Q", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "keyVersion", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array

# 钱箱更换数据通知
def MoneyTicketBox():
    array = []

    # 头
    dic = {"name": "更换时间", "len": 4, "str": ">I", "offset": 0, "date": "localtime"}
    array.append(dic)
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    # 数据
    dic = {"name": "操作对象", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作类型", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "钱箱ID", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "更换状态", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作金额", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 6.1.16　7004-TVM故障退款通知
def TvmFaultRefund():
    array = []

    # 头
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": 0}
    array.append(dic)
    # dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    # array.append(dic)
    # 数据
    dic = {"name": "退款流水号", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "退款时间", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "退款金额", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# 6.1.17　7005-BOM故障退款通知
def BomFaultRefund():
    array = []

    # 设备节点码
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": 0}
    array.append(dic)
    # 退款设备节点码
    dic = {"name": ["设备类型", "线路ID", "车站ID", "设备序号"], "len": 4, "str": ">4B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    # 数据
    dic = {"name": "退款流水号", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "退款时间", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "退款金额", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array


# ========7月15日 新添加数据类型=========

#  1.1.1.1PACC交易-TxnProductMultirideUseOnEntry
def TxnProductMultirideUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "valuePerRide", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.2PACC交易-TxnProductPassUseOnEntry
def TxnProductPassUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.3PACC交易-TxnProductPurseUseOnEntry
def TxnProductPurseUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "totalJourneyAmount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.4PACC交易-TxnProductMultirideUseOnExit
def TxnProductMultirideUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "cardCaptured", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "valuePerRide", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.5PACC交易-TxnProductPassUseOnExit
def TxnProductPassUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.6PACC交易-TxnProductPurseUseOnExit
def TxnProductPurseUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "cardCaptured", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "totalJourneyAmount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.7PACC交易-TxnProductDelayMultirideUseOnEntry
def TxnProductDelayMultirideUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "valuePerRide", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.8PACC交易-TxnProductDelayPassUseOnEntry
def TxnProductDelayPassUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.9PACC交易-TxnProductDelayPurseUseOnEntry
def TxnProductDelayPurseUseOnEntry():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "startOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "totalJourneyAmount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.10PACC交易-TxnProductDelayMultirideUseOnExit
def TxnProductDelayMultirideUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdMultirideLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "valuePerRide", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.11PACC交易-TxnProductDelayPassUseOnExit
def TxnProductDelayPassUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdProductValidity_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPassLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array


#  1.1.1.12PACC交易-TxnProductDelayPurseUseOnExit
def TxnProductDelayPurseUseOnExit():
    array = []

    # AFC系统专用头
    dic = {"name": "操作员ID", "len": 3, "str": "<H", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "发生日期", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "数据长度", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "预留 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysComHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysCardCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysAppCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdJourneyHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("SysProductCom_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    arrays = addArray("DevUdPurseCommonHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "transactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "paymentMethod", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "partialTransactionValue", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("DevUdPurseLavHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    dic = {"name": "entryTime", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len'], "date": "localtime"}
    array.append(dic)
    dic = {"name": "totalJourneyAmount", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "endOfJourney", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayDate", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayStationLocation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "delayOperationMode", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "firstUseActivation", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    arrays = addArray("SysSecurityHdr_t", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array

#  ACC对账文件通用头
def ReconciliationFileHeader():
    array = []
    
    dic = {"name": "", "len": 0, "str": "", "offset": 0}
    # 数据传输头
    arrays = addArray("DataTransmissionHeader", dic, array)
    array = arrays[0]
    dic = arrays[1]

    # 对账文件信息头
    arrays = addArray("ReconciliationDataHeader", dic, array)
    array = arrays[0]
    dic = arrays[1]

    return array

#  1.3.1	地铁对帐范围数据（16字节）
def ReconciliationScopeData():
    array = []

    dic = {"name": "", "len": 0, "str": "", "offset": 0}
    # 交易数据包编号
    arrays = addArray("TxnPkgId", dic, array)
    array = arrays[0]
    dic = arrays[1]
        
    dic = {"name": "FileState", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
 
    return array

#  1.3.2	地铁对帐错误明细数据（86字节）
def ReconciliationErrorDetail():
    array = []

    dic = {"name": "CentSeq", "len": 4, "str": "<I", "offset": 0}
    array.append(dic)

    # 交易数据包编号
    arrays = addArray("TxnPkgId", dic, array)
    array = arrays[0]
    dic = arrays[1]
        
    dic = {"name": "包中记录序号 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易子类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备交易流水号 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易发生日期 ", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 ", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "SAM机具号 ", "len": 6, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "SAM流水号 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "主卡类型 ", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "子卡类型 ", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票卡ID ", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡物理序列号 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡计数器 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易前余额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "长安通卡押金 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易后余额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易认证码 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "可疑原因 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
 
    return array

#  1.3.3	地铁对帐调整明细数据（60字节）
def ReconciliationAdjustDetail():
    array = []

    dic = {"name": "可疑交易检出清算日期 ", "len": 4, "str": "", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "CentSeq", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    # 交易数据包编号
    arrays = addArray("TxnPkgId", dic, array)
    array = arrays[0]
    dic = arrays[1]
        
    dic = {"name": "包中记录序号 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备交易流水号 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易子类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易发生日期 ", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 ", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "票卡ID ", "len": 8, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "卡计数器 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "调整后交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "调整后长安通卡押金 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "调整标志位 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
 
    return array

#  1.3.4	地铁对帐统计数据（42字节）
def ReconciliationStatData():
    array = []

    dic = {"name": "设备类型 ", "len": 1, "str": "<B", "offset": 0}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易子类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "正确交易笔数 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "正确押金金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "正确交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "错误交易笔数 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "错误押金金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "错误交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    dic = {"name": "调整交易笔数 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "调整押金金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "调整交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
 
    return array

#  1.3.5	地铁二维码电子票对帐错误明细数据（103字节）
def ReconciliationQrTicketError():
    array = []

    dic = {"name": "CentSeq", "len": 4, "str": "<I", "offset": 0}
    array.append(dic)

    # 交易数据包编号
    arrays = addArray("TxnPkgId", dic, array)
    array = arrays[0]
    dic = arrays[1]
        
    dic = {"name": "包中记录序号 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易子类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "设备交易流水号 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    
    dic = {"name": "设备类型 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路ID", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站编号", "len": 1, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "站内设备编号 ", "len": 1, "str": "<B", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    
    dic = {"name": "交易发生日期 ", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "交易发生时间 ", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    
    dic = {"name": "终端订单号", "len": 64, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    
    dic = {"name": "可疑原因 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
 
    return array

#  1.3.7	清分对账文件（74字节）
def ReconciliationCleanData():
    array = []

    dic = {"name": "清算日期 ", "len": 4, "str": "", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "运营统计日期 ", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "线路运营商ID ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "线路编号 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "进站编号", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "出站编码", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车票发行商 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票种 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易状态 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易数量 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    
    dic = {"name": "清分金额", "len": 20, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)
    
    dic = {"name": "清分次数", "len": 20, "str": "", "offset": dic["offset"] + dic['len'], "type": "ASCII"}
    array.append(dic)

    dic = {"name": "清分类型 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
     
    return array
    
#  1.3.6	现金收益对账文件（38字节）
def ReconciliationCashIncome():
    array = []

    dic = {"name": "清算日期 ", "len": 4, "str": "", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "线路运营商ID ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "车站ID", "len": 2, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车站ID", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "车票发行商 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "票种 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易状态 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "支付类型 ", "len": 2, "str": "<H", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易数量 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "单位交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易次数 ", "len": 4, "str": "<I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
   
    return array

# 6.5.3　4012-票房售票机结帐数据
def BOMSettleDataHead():
    array = []

    dic = {"name": "设备节点标识码 ", "len": 4, "str": "", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "结算序列号 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "结帐时间 ", "len": 4, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "结算开始时间 ", "len": 7, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "结算结束时间 ", "len": 7, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)
    dic = {"name": "结算操作员 ", "len": 3, "str": "", "offset": dic["offset"] + dic['len'], "type": "BCD"}
    array.append(dic)

    return array

def BOMSettleDataBody():
    array = []

    dic = {"name": "结帐日期 ", "len": 4, "str": "", "offset": 0, "type": "BCD"}
    array.append(dic)
    dic = {"name": "产品种类 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "产品子类型 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易类型 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易子类型 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易数量 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "押金金额 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易金额 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "交易手续费金额 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "卡成本费金额 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "支付方式 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留1 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留2 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留3 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留4 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留5 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)
    dic = {"name": "保留6 ", "len": 4, "str": ">I", "offset": dic["offset"] + dic['len']}
    array.append(dic)

    return array